<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <input type="text">
</body>

</html>
<script>
    const inEle = document.querySelector('input')
    function fn() {
        console.log('糟糕，有内奸，，停止交易，，我是防抖，我是防抖！！！');
    }
    function ss(sss, ttt) {
        let timerid = null;
        return function () {
            if (timerid) {
                clearTimeout(timerid)
            }
            timerid = setTimeout(() => {
                sss()
            }, ttt)

        }
    }
    inEle.oninput = ss(fn, 1000)
</script>